<!--
var setting = {
	async: {
		enable: true,
		url:"../asyncData/getNodes.php",
		autoParam:["id", "name=n"],
		otherParam:{"otherParam":"zTreeAsyncTest"},
		dataFilter: filter
	},
	callback: {
		beforeAsync: beforeAsync
	}
};

function filter(treeId, parentNode, childNodes) {
	if (!childNodes) return null;
	for (var i=0, l=childNodes.length; i<l; i++) {
		childNodes[i].name = childNodes[i].name.replace(/\.n/g, '.');
	}
	return childNodes;
}
function beforeAsync(treeId, treeNode) {
	return treeNode ? treeNode.level < 5 : true;
}

$(document).ready(function(){
	$.fn.zTree.init($("#treeDemo"), setting);
});
//-->